package com.micolor.logr.demo.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.micolor.logr.runtime.annotation.LogField;
import com.micolor.logr.runtime.util.DateFormatUtil;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
/**
 * @author EvanGe
 * @Type BaseEntity.java
 * @Desc
 * @date 2024/7/8 10:57
 */
@Data
public class BaseEntity implements Serializable {

    @LogField(value="创建人编号")
    @TableField("create_by")
    private String createBy;

    @LogField(value = "创建时间",isCreateTime=true,dateFormat = DateFormatUtil.YMD_HMS)
    @TableField("create_time")
    private Date createTime;

    @LogField(value="更新人")
    @TableField("update_by")
    private String updateBy;

    @LogField(value = "创建时间",isUpdateTime=true,dateFormat = DateFormatUtil.YMD_HMS)
    @TableField("update_time")
    private Date updateTime;

    @LogField(value="备注信息")
    @TableField("remark")
    private String remark;

    @LogField(value = "创建人名称",isCreateOperator = true)
    @TableField(exist = false)
    private String createByName;

    @LogField(value = "更新人名称",isUpdateOperator = true)
    @TableField(exist = false)
    private String updateByName;
}
